
<ul class="page-sidebar-menu">
    @foreach($menu as $k => $v)
        <li class="{{ !empty($v['page_name']) && in_array($page_name, $v['page_name']) ? 'active' : '' }}">
            <a href="{{ !@$v['url'] ? "javascript:;" : @$v['url'] }}" {{ @$v['target'] ? 'target='.$v['target'].'' : '' }}>
                <i class="fa fa-{{ @$v['icon'] }}"></i>
                <span class="title">{{ @$v['text'] }}</span>
            </a>
            @empty($v['sub'])
            @else
                <ul class="sub-menu">
                    @foreach($v['sub'] as $ssu)
                        <li>
                            <a href="{{ @$ssu['url'] }}" {{ @$ssu['target'] ? 'target="'.$ssu['target'].'"' : '' }}>{{ @$ssu['text'] }}</a>
                        </li>
                    @endforeach
                </ul>
            @endif
        </li>
    @endforeach
</ul>